/**

This file is part of MaCI/GIMnet.

MaCI/GIMnet is free software: you can redistribute it and/or modify it 
under the terms of the GNU Lesser General Public License as published 
by the Free Software Foundation, either version 3 of the License, or 
(at your option) any later version.

MaCI/GIMnet is distributed in the hope that it will be useful, but WITHOUT 
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public 
License for more details.

You should have received a copy of the GNU Lesser General Public 
License along with GIMnet. (See COPYING.LESSER) If not, see 
<http://www.gnu.org/licenses/>.

**/
/*
* Skywalker dimensions and settings
* units are meters
*/

//distance from ground to the base of the hull
#define GROUND_CLEARANCE 0.03
//bumper location measured from the base of the hull
#define LOWER_CYLINDER_HEIGHT 0.160
#define LOWER_CYLINDER_RADIUS 0.260
//hull dimensions
#define UPPER_CYLINDER_RADIUS 0.200
#define UPPER_CYLINDER_HEIGHT (0.170+LOWER_CYLINDER_HEIGHT)
//driwing wheels
#define DRIVING_WHEEL_RADIUS 0.065
#define DRIVING_WHEEL_WIDTH 0.026
//driving wheel distance from robots center
#define DRIVING_WHEEL_X 0.160
#define WHEELBASE (2*DRIVING_WHEEL_X)
//caster wheels
#define CASTER_WHEEL_RADIUS 0.01
//caster wheel distance from robots center
#define CASTER_WHEEL_Z 0.230
//robot works best when casters are a bit off ground
#define CASTER_WHEEL_Y 0.001

//laser scanner position
#define SCANNER_OFFSET_Z (UPPER_CYLINDER_HEIGHT/2+0.03)
#define SCANNER_OFFSET_X (0.095)

//camera position
#define CAMERA_OFFSET_X 0.1
#define CAMERA_OFFSET_Z 0.4

//hull z-coordinate
#define LOWER_CYLINDER_Y (GROUND_CLEARANCE+LOWER_CYLINDER_HEIGHT/2)
#define UPPER_CYLINDER_Y (GROUND_CLEARANCE+UPPER_CYLINDER_HEIGHT/2)

//other settings
#define MAX_MOTOR_SPEED 1.5 //m/s
#define MAX_ANGULAR_SPEED (MAX_MOTOR_SPEED/DRIVING_WHEEL_X)
#define MAX_ACCELERATION 0.2

#define AXLE_FRICTION_TORQUE 0.2

//how often sensor data is sent
#define LASER_INTERVAL 0.125
#define POSITION_INTERVAL 0.05

//GIMI stuff
#define MINOR_TYPE_LASER 0
#define MINOR_TYPE_BUMPER 1
